'use strict';
exports.main = async (event, context) => {
	try {
	
		const res = await uniCloud.getPhoneNumber({
			appid: '__UNI__180DEE6', // 客户端callFunction时携带的AppId信息
			provider: 'univerify',
			access_token: event.access_token,
			openid: event.openid,
			
		})
		// 返回给客服端的数据
		return {
			state: true,
			code: 200,
			message: '获取手机号成功',
			res: res.result,
			result: res
		}
	} catch (e) {
		
		return {
			state: false,
			code: 400,
			message: '获取手机号失败',
			err: e.toString(),
			
		}
	}
};